package com.chenqq.camerademo.camera.usbInterface;

import android.hardware.usb.UsbDevice;

import com.chenqq.camerademo.camera.usb.UsbControlBlock;

public interface OnDeviceConnectListener {
    /**
     * called after device opend
     * @param device
     * @param ctrlBlock
     * @param createNew
     */
    public void onConnect(String Tag,UsbDevice device, UsbControlBlock ctrlBlock, boolean createNew);
    /**
     * called when USB device removed or its power off (this callback is called after device closing)
     * @param device
     * @param ctrlBlock
     */
    public void onDisconnect(UsbDevice device, UsbControlBlock ctrlBlock);
    /**
     * called when canceled or could not get permission from user
     * @param device
     */
    public void onCancel(UsbDevice device);
}
